package com.yaodian100.ec.giftcard.entity;

import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

import com.yaodian100.core.common.entity.BaseEntity;

@Entity
@Table(name = "EC_GIFTCARD_MAIN")
public class GiftcardMain extends BaseEntity {

	/** serial version */
	private static final long serialVersionUID = -4648935023005383558L;
	
	/** 禮品卡主檔編號 */
	@Id
	@GeneratedValue(strategy = GenerationType.AUTO, generator = "seq_ec_giftcard_main")
	@SequenceGenerator(name = "seq_ec_giftcard_main", sequenceName = "SEQ_EC_GIFTCARD_MAIN")
	@Column(name = "MAIN_ID")
	private Long mainId;
	
	/** 申請人 */
	@Column(name = "APPLY_USER", length = 30)
	private String applyUser;
	
	/** 申請日期 */
	@Temporal(TemporalType.TIMESTAMP)
	@Column(name = "APPLY_DATE")
	private Date applyDate;
	
	/** 充值期限 */
	@Temporal(TemporalType.TIMESTAMP)
	@Column(name = "RECHARGE_DEADLINE")
	private Date rechargeDeadline;
	
	/** 禮品卡名稱 */
	@Column(name = "GIFTCARD_NAME", length = 100)
	private String giftcardName;

	// getter & setter
	public Long getMainId() {
		return mainId;
	}

	public void setMainId(Long mainId) {
		this.mainId = mainId;
	}

	public String getApplyUser() {
		return applyUser;
	}

	public void setApplyUser(String applyUser) {
		this.applyUser = applyUser;
	}

	public Date getApplyDate() {
		return applyDate;
	}

	public void setApplyDate(Date applyDate) {
		this.applyDate = applyDate;
	}

	public Date getRechargeDeadline() {
		return rechargeDeadline;
	}

	public void setRechargeDeadline(Date rechargeDeadline) {
		this.rechargeDeadline = rechargeDeadline;
	}

	public String getGiftcardName() {
		return giftcardName;
	}

	public void setGiftcardName(String giftcardName) {
		this.giftcardName = giftcardName;
	}
}